package com.ruoyi.finance.domain;

import java.math.BigDecimal;
import java.util.List;
import java.util.Date;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.core.annotation.Excel;
import com.ruoyi.common.core.web.domain.BaseEntity;

/**
 * 凭证管理对象 t_voucher
 * 
 * @author ruoyi
 * @date 2025-02-27
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class TVoucher
{
    private static final long serialVersionUID = 1L;

    /** 凭证id */
    @Excel(name = "凭证id")
    @TableId(type = IdType.AUTO)
    private Long id;

    /** 凭证字号 */
    @Excel(name = "凭证字号")
    private String number;

    /** 开据凭证日期 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "开据凭证日期", width = 30, dateFormat = "yyyy-MM-dd")
    private Date voucherDate;

    /** 账期 */
    @Excel(name = "账期")
    private String accountingPeriod;

    /** 附单据数量 */
    @Excel(name = "附单据数量")
    private Long attachmentCount;

    /** 合计金额 */
    @Excel(name = "合计金额")
    private BigDecimal totalAmount;

    /** 剩余可冲销金额 */
    @Excel(name = "剩余可冲销金额")
    private BigDecimal remainingReversalAmount;

    /** 审核人id */
    @Excel(name = "审核人id")
    private Long auditorId;

    /** 审核状态 */
    @Excel(name = "审核状态")
    private Long auditStatus;

    /** 审核时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "审核时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date auditTime;

    /** 作废状态 */
    @Excel(name = "作废状态")
    private Integer voidStatus;

    /** 作废时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "作废时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date voidTime;

    /** 红冲时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "红冲时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date reversalTime;

    /** 账套 */
    @Excel(name = "账套")
    private Long accountSetId;

    /** 凭证字 */
    @Excel(name = "凭证字")
    private Long wordId;

    /** 附件 */
    @Excel(name = "附件")
    private String accessory;

    /**
     * 创建人
     */
    @TableField(fill = FieldFill.INSERT)
    private Long createId;
    @TableField(fill = FieldFill.INSERT)
    private Date createTime;

    /**
     * 修改人
     */
    @TableField(fill = FieldFill.UPDATE)
    private Long updateId;
    @TableField(fill = FieldFill.UPDATE)
    private Date updateTime;

    /**
     * 逻辑删除
     */
    @TableField(fill = FieldFill.INSERT)
    private Long deleteType;

    /** 版本号 */
    @TableField(fill = FieldFill.INSERT)
    private Long bbNumber;

    /** 凭证明细信息 */
    @TableField(exist = false)
    private List<TVoucherDetail> detailList;

    @TableField(exist = false)
    private String tasName;
    @TableField(exist = false)
    private String tvwName;
    @TableField(exist = false)
    private String userName;


}
